3.42 \(\int \csc ^6(e+f x) (a+b \tan ^2(e+f x)) \, dx\)

Optimal. Leaf size=64 \[ -\frac {(2 a+b) \cot ^3(e+f x)}{3 f}-\frac {(a+2 b) \cot (e+f x)}{f}-\frac {a \cot ^5(e+f x)}{5 f}+\frac {b \tan (e+f x)}{f} \]

[Out]

-(a+2*b)*cot(f*x+e)/f-1/3*(2*a+b)*cot(f*x+e)^3/f-1/5*a*cot(f*x+e)^5/f+b*tan(f*x+e)/f

________________________________________________________________________________________

Rubi [A]  time = 0.05, antiderivative size = 64, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.095, Rules used = {3663, 448} \[ -\frac {(2 a+b) \cot ^3(e+f x)}{3 f}-\frac {(a+2 b) \cot (e+f x)}{f}-\frac {a \cot ^5(e+f x)}{5 f}+\frac {b \tan (e+f x)}{f} \]

Antiderivative was successfully verified.

[In]

Int[Csc[e + f*x]^6*(a + b*Tan[e + f*x]^2),x]

[Out]

-(((a + 2*b)*Cot[e + f*x])/f) - ((2*a + b)*Cot[e + f*x]^3)/(3*f) - (a*Cot[e + f*x]^5)/(5*f) + (b*Tan[e + f*x])
/f

Rule 448

Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.)*((c_) + (d_.)*(x_)^(n_))^(q_.), x_Symbol] :> Int[ExpandI
ntegrand[(e*x)^m*(a + b*x^n)^p*(c + d*x^n)^q, x], x] /; FreeQ[{a, b, c, d, e, m, n}, x] && NeQ[b*c - a*d, 0] &
& IGtQ[p, 0] && IGtQ[q, 0]

Rule 3663

Int[sin[(e_.) + (f_.)*(x_)]^(m_)*((a_) + (b_.)*((c_.)*tan[(e_.) + (f_.)*(x_)])^(n_))^(p_.), x_Symbol] :> With[
{ff = FreeFactors[Tan[e + f*x], x]}, Dist[(c*ff^(m + 1))/f, Subst[Int[(x^m*(a + b*(ff*x)^n)^p)/(c^2 + ff^2*x^2
)^(m/2 + 1), x], x, (c*Tan[e + f*x])/ff], x]] /; FreeQ[{a, b, c, e, f, n, p}, x] && IntegerQ[m/2]

Rubi steps

\begin {align*} \int \csc ^6(e+f x) \left (a+b \tan ^2(e+f x)\right ) \, dx &=\frac {\operatorname {Subst}\left (\int \frac {\left (1+x^2\right )^2 \left (a+b x^2\right )}{x^6} \, dx,x,\tan (e+f x)\right )}{f}\\ &=\frac {\operatorname {Subst}\left (\int \left (b+\frac {a}{x^6}+\frac {2 a+b}{x^4}+\frac {a+2 b}{x^2}\right ) \, dx,x,\tan (e+f x)\right )}{f}\\ &=-\frac {(a+2 b) \cot (e+f x)}{f}-\frac {(2 a+b) \cot ^3(e+f x)}{3 f}-\frac {a \cot ^5(e+f x)}{5 f}+\frac {b \tan (e+f x)}{f}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.05, size = 106, normalized size = 1.66 \[ -\frac {8 a \cot (e+f x)}{15 f}-\frac {a \cot (e+f x) \csc ^4(e+f x)}{5 f}-\frac {4 a \cot (e+f x) \csc ^2(e+f x)}{15 f}+\frac {b \tan (e+f x)}{f}-\frac {5 b \cot (e+f x)}{3 f}-\frac {b \cot (e+f x) \csc ^2(e+f x)}{3 f} \]

Antiderivative was successfully verified.

[In]

Integrate[Csc[e + f*x]^6*(a + b*Tan[e + f*x]^2),x]

[Out]

(-8*a*Cot[e + f*x])/(15*f) - (5*b*Cot[e + f*x])/(3*f) - (4*a*Cot[e + f*x]*Csc[e + f*x]^2)/(15*f) - (b*Cot[e +
f*x]*Csc[e + f*x]^2)/(3*f) - (a*Cot[e + f*x]*Csc[e + f*x]^4)/(5*f) + (b*Tan[e + f*x])/f

________________________________________________________________________________________

fricas [A]  time = 0.44, size = 91, normalized size = 1.42 \[ -\frac {8 \, {\left (a + 5 \, b\right )} \cos \left (f x + e\right )^{6} - 20 \, {\left (a + 5 \, b\right )} \cos \left (f x + e\right )^{4} + 15 \, {\left (a + 5 \, b\right )} \cos \left (f x + e\right )^{2} - 15 \, b}{15 \, {\left (f \cos \left (f x + e\right )^{5} - 2 \, f \cos \left (f x + e\right )^{3} + f \cos \left (f x + e\right )\right )} \sin \left (f x + e\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(f*x+e)^6*(a+b*tan(f*x+e)^2),x, algorithm="fricas")

[Out]

-1/15*(8*(a + 5*b)*cos(f*x + e)^6 - 20*(a + 5*b)*cos(f*x + e)^4 + 15*(a + 5*b)*cos(f*x + e)^2 - 15*b)/((f*cos(
f*x + e)^5 - 2*f*cos(f*x + e)^3 + f*cos(f*x + e))*sin(f*x + e))

________________________________________________________________________________________

giac [A]  time = 1.37, size = 79, normalized size = 1.23 \[ \frac {15 \, b \tan \left (f x + e\right ) - \frac {15 \, a \tan \left (f x + e\right )^{4} + 30 \, b \tan \left (f x + e\right )^{4} + 10 \, a \tan \left (f x + e\right )^{2} + 5 \, b \tan \left (f x + e\right )^{2} + 3 \, a}{\tan \left (f x + e\right )^{5}}}{15 \, f} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(f*x+e)^6*(a+b*tan(f*x+e)^2),x, algorithm="giac")

[Out]

1/15*(15*b*tan(f*x + e) - (15*a*tan(f*x + e)^4 + 30*b*tan(f*x + e)^4 + 10*a*tan(f*x + e)^2 + 5*b*tan(f*x + e)^
2 + 3*a)/tan(f*x + e)^5)/f

________________________________________________________________________________________

maple [A]  time = 0.71, size = 83, normalized size = 1.30 \[ \frac {a \left (-\frac {8}{15}-\frac {\left (\csc ^{4}\left (f x +e \right )\right )}{5}-\frac {4 \left (\csc ^{2}\left (f x +e \right )\right )}{15}\right ) \cot \left (f x +e \right )+b \left (-\frac {1}{3 \sin \left (f x +e \right )^{3} \cos \left (f x +e \right )}+\frac {4}{3 \sin \left (f x +e \right ) \cos \left (f x +e \right )}-\frac {8 \cot \left (f x +e \right )}{3}\right )}{f} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(csc(f*x+e)^6*(a+b*tan(f*x+e)^2),x)

[Out]

1/f*(a*(-8/15-1/5*csc(f*x+e)^4-4/15*csc(f*x+e)^2)*cot(f*x+e)+b*(-1/3/sin(f*x+e)^3/cos(f*x+e)+4/3/sin(f*x+e)/co
s(f*x+e)-8/3*cot(f*x+e)))

________________________________________________________________________________________

maxima [A]  time = 0.63, size = 59, normalized size = 0.92 \[ \frac {15 \, b \tan \left (f x + e\right ) - \frac {15 \, {\left (a + 2 \, b\right )} \tan \left (f x + e\right )^{4} + 5 \, {\left (2 \, a + b\right )} \tan \left (f x + e\right )^{2} + 3 \, a}{\tan \left (f x + e\right )^{5}}}{15 \, f} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(f*x+e)^6*(a+b*tan(f*x+e)^2),x, algorithm="maxima")

[Out]

1/15*(15*b*tan(f*x + e) - (15*(a + 2*b)*tan(f*x + e)^4 + 5*(2*a + b)*tan(f*x + e)^2 + 3*a)/tan(f*x + e)^5)/f

________________________________________________________________________________________

mupad [B]  time = 11.41, size = 59, normalized size = 0.92 \[ \frac {b\,\mathrm {tan}\left (e+f\,x\right )}{f}-\frac {\left (a+2\,b\right )\,{\mathrm {tan}\left (e+f\,x\right )}^4+\left (\frac {2\,a}{3}+\frac {b}{3}\right )\,{\mathrm {tan}\left (e+f\,x\right )}^2+\frac {a}{5}}{f\,{\mathrm {tan}\left (e+f\,x\right )}^5} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a + b*tan(e + f*x)^2)/sin(e + f*x)^6,x)

[Out]

(b*tan(e + f*x))/f - (a/5 + tan(e + f*x)^2*((2*a)/3 + b/3) + tan(e + f*x)^4*(a + 2*b))/(f*tan(e + f*x)^5)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \left (a + b \tan ^{2}{\left (e + f x \right )}\right ) \csc ^{6}{\left (e + f x \right )}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(f*x+e)**6*(a+b*tan(f*x+e)**2),x)

[Out]

Integral((a + b*tan(e + f*x)**2)*csc(e + f*x)**6, x)

________________________________________________________________________________________